﻿//------------------------------------------------------------
// Game Framework
// Copyright © 2013-2021 Jiang Yin. All rights reserved.
// Homepage: https://gameframework.cn/
// Feedback: mailto:ellan@gameframework.cn
//------------------------------------------------------------

using Cinemachine;
using GameFramework;
using GameFramework.Fsm;
using System;
using UnityEngine;
using UnityGameFramework.Runtime;

namespace Adventure
{
    public class EnemyEntityBee : EnemyEntity
    {
        private IFsm<EnemyEntityBee> fsm;
        protected override void OnInit(object userData)
        {
            base.OnInit(userData);

            fsm = GameEntry.Fsm.CreateFsm<EnemyEntityBee>("BeeFSM", this,
                new IdleStateBee(),
                new PatrolStateBee(),
                new AttackStateBee(),
                new HitStateBee(),
                new DeathStateBee()
                );

            groundOffset = new Vector2(0, 2);
            touchLeftOffset = new Vector2(0, 2);
            touchRightOffset = new Vector2(0, 2);
        }
        protected override void OnShow(object userData)
        {
            base.OnShow(userData);
            fsm.Start<IdleStateBee>();
        }

        protected override void OnRecycle()
        {
            base.OnRecycle();
            GameEntry.Fsm.DestroyFsm(fsm);
        }
    }
    public class IdleStateBee : FsmState<EnemyEntityBee>
    {

    }
    public class PatrolStateBee : FsmState<EnemyEntityBee>
    {

    }
    public class AttackStateBee : FsmState<EnemyEntityBee>
    {

    }
    public class HitStateBee : FsmState<EnemyEntityBee>
    {

    }
    public class DeathStateBee : FsmState<EnemyEntityBee>
    {

    }


}
